﻿	<table class="table table-bordered">
	<thead>
		<tr>
			<th style="width:30%;">Atividade</th>
			<th style="width:25%;">Período</th>
			<th style="width:25%;">Responsável</th>
			<th style="width:10%;">Editar</th>
			<th style="width:10%;">Cancelar</th>
		</tr>
	</thead>
	<tbody>
	<?php if(isset($periodos)) foreach($periodos as $periodo): ?>
		<tr>
			<td>
				<strong><?php echo Html::anchor('reserva/ver/'.$periodo->reserva->id, strtoupper($periodo->reserva->atividade)); ?></strong>
			</td>
			<td>
				<p>Dia: <strong><?php echo date('d/m/Y', $periodo->inicio); ?></strong></p>
				<p>Horário: <strong><?php echo date('H:i', $periodo->inicio), 'h às ', date('H:i', $periodo->fim),'h'; ?></strong></p>
				<p><?php echo Html::anchor('reserva/adicionarperiodo/'.$periodo->reserva->id,'Adicionar novo Período'); ?></p>
			</td>
			<td><?php echo Html::anchor('responsavel/ver/'.$periodo->reserva->responsavel->id, $periodo->reserva->responsavel->nome, array('title' => 'Dados do Responsável e suas Reservas')); ?></td>
			<td><?php echo Html::anchor('reserva/editar/'.$periodo->reserva->id, 'Editar'); ?></td>
			<td><?php echo Html::anchor('reserva/apagar/'.$periodo->reserva->id, 'Cancelar'); ?></td>
		</tr>
	<?php endforeach; ?>
	</tbody>
	</table>